import { _decorator, Component, director, Label, labelAssembler, Node } from 'cc';
import { LayerBase } from '../utils/LayerBase';
import { UILayerMgr } from '../utils/UILayerMgr';
import { GateGamePanel } from './GateGamePanel';
import { AudioMgr } from '../utils/AudioMgr';
import { Adsdk } from './Adsdk';
const { ccclass, property } = _decorator;

@ccclass('GateFailPanel')
export class GateFailPanel extends LayerBase {

    init(somedData?: any): void {
        Adsdk.instance.showInterstitialAd();

    }

    onclickComfirmBtn(){
        UILayerMgr.getIns.closeAllLayer();
    }

    onclickReviveBtn(){
        UILayerMgr.getIns.closeUILayer(this.node.name);
        GateGamePanel.ins.revive();
    }

}


